#include<iostream>
#include<cstring>

class Student
{
    public:
        void SetID(int id)
        {
            m_id= id;
        }
        void SetName(const char *name)
        {
            strcpy(m_Name, name);
        }
        void Print()
        {
            std::cout<<m_id<<" "<<m_Name<<std::endl;
        }

    private:
        int m_id;                 //一般在类的成员变量前面加上m_
        char m_Name[20];
};

int main()
{
    Student s;
    s.SetID(10);
    s.SetName("zhangsan");
    s.Print();
    return 0;
}